package com.wcity.manage.dao.mapper;

import com.wcity.manage.dao.dal.BaseMapper;
import com.wcity.manage.dao.dal.model.PageModel;
import com.wcity.manage.dao.model.Announcement;
import com.wcity.manage.dao.model.Block;
import com.wcity.manage.dao.model.SeedAnn;
import org.springframework.stereotype.Repository;

import java.io.Serializable;
import java.util.List;

/**
 * 公告管理
 * Created by zm on 2016/12/15.
 */
@Repository
public interface AnnouncementMapper extends BaseMapper<Announcement, Serializable> {
    /**
     * 获取小区名称
     * @param id
     * @return
     */
    List<Block> getBlockName(int id);

    /**
     * 获取公告信息
     * @param id
     * @return
     */
    Announcement getAnnInfo(String id );

    /**
     * 发送公告
     * @param seedAnn
     * @return
     */
    int sendAdd (SeedAnn seedAnn);

    Announcement getAnnInfo1(String annId, String blockId);

    /**
     * 获取最新的物业公告
     * @param blockId
     * @return
     */
    Announcement getProNewAnn(String blockId);

    /**
     * 获取最新的社区公告
     * @param blockId
     * @return
     */
    Announcement getComNewAnn(String blockId);
}
